cmake_minimum_required(VERSION 3.17)
project(add_exe_5)

add_executable(mytest IMPORTED)
set_property(TARGET mytest PROPERTY IMPORTED_LOCATION "${PROJECT_SOURCE_DIR}/sub/build/mytest")

add_custom_command(OUTPUT custom_command COMMAND mytest)
add_custom_target(custom_target DEPENDS custom_command)
